package com.lh.createData.service.Impl;

import com.lh.createData.dao.MenuMapper;
import com.lh.createData.model.InPutParam.MenuInParam;
import com.lh.createData.service.MenuService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.Date;

/**
 * @author ：梁昊，后端工程师：梁昊
 * @create 2021-08-11 12:00
 * @function
 * @editLog
 */
@SuppressWarnings("SpringJavaInjectionPointsAutowiringInspection")
@Service
public class MenuServiceImpl implements MenuService {
    @Autowired
    MenuMapper menuMapper;

    /**
     * 增加项目、产品、菜单关系
     *
     * @param menuInParam com.lh.createData.model.InPutParam.MenuInParam
     * @return 影响条数
     */
    @Override
    public int insertMenu (MenuInParam menuInParam) {
        return menuMapper.insertMenu(menuInParam);
    }

    /**
     * 增加项目、产品、菜单关系
     *
     * @param menuInParam com.lh.createData.model.InPutParam.MenuInParam
     * @return 影响条数
     */
    @Override
    public int insertMenuBeforeCheck(MenuInParam menuInParam) {
        return menuMapper.insertMenuBeforeCheck(menuInParam);
    }

    @Override
    public int deleteFromMenu(MenuInParam menuInParam) {
        return menuMapper.deleteFromMenu(menuInParam);
    }
}
